<form action="sqlback.manage.php?action=backup" method="POST" id="form1" name="form1">
  <table class="from_table2_one">

    <tr class="area_ajax_list_title">
      <th class="pd-left" width="280" ><tpl> $langSysSQLTableName </tpl></th>
      <th width="200" ><tpl> $langSysSQLTableType </tpl></th>
      <th width="100"><tpl> $langSysSQLNoteNum </tpl></th>
	  <th width="100"><div style="margin-top:2px;*margin-top:-2px;"><span class="btn_left"><input type="button" value="<tpl> $langSysSQLOptimizeDatabase </tpl>" id="optimize_button" class="btn_submit"/></span></div></th>
    </tr>
	
    <tpl> section name=i loop=$sql_array </tpl>
    <tr>
      <td class="pd-left" width="280" align="left" class="td1"><tpl> $sql_array[i].Name </tpl></td>
      <td width="200" align="left"><tpl> $sql_array[i].Engine </tpl></td>
      <td width="100" align="left"><tpl> $sql_array[i].Rows </tpl></td>
	  <td width="100"></td>
    </tr>
    <tpl> /section </tpl>
  </table>
 </form>

<script>
$().ready(function() {
	var ShowDiv = 'result_content';

	$('#optimize_button').click(
	function(){
		var showText = "<tpl> $langSysSQLOptimize </tpl>...";
		var msg = "<tpl> $langSysSQLOptimizeDatabaseOk </tpl>";
		$.ajax({
			url: 'sqlback.manage.php?action=optimize',
			type: 'get',
			dataType: 'json',
			beforeSubmit: showLoading(showText),
			success: function(){
				hideLoading();
				showMessage(msg);
			}
		});
	}
	);

});
</script>